home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
EnigmA Amiga Run 1996 July
/
EnigmA AMIGA RUN 09 (1996)(G.R. Edizioni)(IT)[!][issue 1996-07 & 08][EARSAN CD VIII].iso
/
earcd
/
comm2
/
npns.lha
/
NPNS
/
NewPostNewsSpool.doc
next >
Wrap
Text File
|
1996-05-29
|
9KB
|
329 lines
New Post News Spool 5.5
Nick d'Alterio - May 1996
« Introduction »
« Installation »
« Updating »
« Online check »
« sendnews »
« postnews »
« History »
« Bugs »
« Conditions of Use »
« Future Plans »
« Thanks »
« The Author »
Introduction
This pair of programs provide a method of spooling news so that you
can write your articles while offline and then send them off once
you go online.
The original version was based on PostNewsSpool by James Burton, but
this has long been left behind in terms of features. The latest version
now no longer requires an external posting agent.
AmiTCP only
Installation
Copy sendnews and postnews to somewhere on your path and set the
appropriate environment variables described below.
postnews should be the program that is called by your news reading
program to post the news. This will spool the article so that you
can use sendnews to send it off when you go online.
Updating From Previous Versions
Updates from 5.2 to 5.5 :-
Read the docs since both sendnews and postnews have new arguments
Updates from 4.x to 5.2 :-
1. sendnews now posts news to the nntp server itself so the env
variable PNS_POSTNEWS now has no use. If your news server
requires authorisation DO NOT use the latest version.
Authorisation is not supported - at least until someone tells
me the procedure for authorisation.
2. Env var PNS_OFFLINE has been changed to NNTPALWAYSQUEUE in line
with SMTPPost.
3. Option -n has been changed to -Q same reason as above.
4. If using Inet225 DO NOT upgrade. If there is enough demand I will
create a version for this stack.
Updates from 3.c to 4.x :-
1. postnews argument -from has now changed to -f.
Updates from 1.x, 2.x to 3.x :-
1. From version 3 sendnews will attempt to send any article
in the spooldir no matter what the name is. So if your news
reader produces a fully formed news article with header you
can drop it straight into the spooldir without using postnews.
2. You should remove the seq file if you had it in your spooldir
and the env variable PNS_SEQFILE
Online Check
Since version 4.2 npns uses an environment variable ONLINE to determine
if the machine is online or not. If this variable is set to 0 then
you are assumed to be offline anything else indicates you are online.
If this variable does not exist then both postnews and sendnews assume
that you are offline.
This variable should be setup in the startnet and stopnet scripts for
best use.
NOTE: Since 5.5 this is not used at all but it is probably a good idea
to keep for online detection by scripts.
sendnews
sendnews now accepts arguments in the standard Amiga readargs format.
Usage: sendnews ALL/S,HELP/S,A=ARTICLES/M
sendnews
If sendnews is run without arguments then it will behave the same as
in previous versions and send all articles in the spool directory to
the news server.
A=ARTICLES/M Following this option should be a list of article
filenames that you want posted to the server. If this
option is used the spooled articles will not be sent
unless the ALL option is used
ALL/S If this switch is used then both the articles in the
spool directory and those specified on the command line
will be sent.
HELP/S Print a small amount of usage information after which
the spooled articles will be sent.
sendnews will send off the articles to the news server if online. If
the posting fails for any reason the failed article will be appended
to the end of the failed archive indicated by PNS_FAILED_ARC
( AmiTCP:Usr/Spool/sendnews.failed by default ). Each file in the
failed archive will be separated by a line containing the date and time
sendnews failed to post the article.
sendnews requires that the environment variable NNTPSERVER is set so
to be able to post the article.
Usage Examples
sendnews Sends spooled articles
sendnews ARTICLES file1 file2 Sends file1 and file2
sendnews ARTICLES file1 ALL Sends spooled articles and file1
postnews
This spools a news article ready for posting when online. The article
can be complete with header (as prepared by tin) or in its component
parts, in which case postnews puts them together so that the article
is ready for posting (Grn style).
It places the article in the spool directory PNS_SPOOLDIR
(AmiTCP:Usr/Spool/News by default). The spooled filename has the
format msg.######### where ###### is a number which refers to the time
of writing.
If online at the time of writing the article then postnews immediately
executes sendnews (which must be on the path) to send off the article.
To stop postnews from sending the article create an environment variable
called NNTPALWAYSQUEUE. This feature has been removed in 5.5 it may
return if there is anyone really wants it.
postnews now uses the standard amiga readargs command line arguments.
Usage: postnews FROM/K,HELP/S,DEL/S,HEAD/K,BODY/K
postnews FROM/K,DEL/S,HEAD/K < article
postnews
If postnews is run with no arguments it expects the fully formed article
to be input via stdin.
FROM/K Add a line to header specifying the sender
HELP/S Print some help then exits
HEAD/K Get the article header from the file specified. If this
option is not used the entire article including header
should be in file BODY/K or on stdin
BODY/K Read body of article from this file or complete article if
HEAD/K option is not used
DEL/S Delete HEAD/K and BODY/K files if posting was successful.
Otherwise leave them untouched.
If BODY/K option is not used, postnews expects to read the body from stdin.
Usage Examples
postnews BODY article Spools fully formed article
postnews < article Spools fully formed article from stdin
postnews BODY article DEL Spools article then deletes original
postnews BODY bod HEADheader Spools article made from header and body
postnews BODY bod HEAD header DEL As above but deletes the original files
e.g. For tin I use
set TIN_POST amitcp:bin/postnews FROM "nagd@oc.ic.ac.uk (Nicholas d'Alterio)" BODY %s
for Grn try
amitcp:bin/postnews BODY .article HEAD .header DEL
History
5.5 - sendnews now has command line options
- postnews command line now uses readargs
- Now uses only ADOS functions
- Compiled with no startup to make 300% smaller
- postnews does not call sendnews anymore
- Removed various bugs in sendnews
5.1 - Now posts news to server itself (AmiTCP only)
- PNS_NNTPPOST removed (redundant)
- PNS_OFFLINE changed to NNTPALWAYSQUEUE
- option -n changed to -Q
- Split up into separate source files
- Minor bugfixes, optimizations
- Made amigaguide documentation
4.2 - Various bugs in online check (schlonz@antilon.ame.osn.de)
Online check system redesigned, should work for any system now.
- Remove -a option. No longer had any purpose.
- Doesn't bother with DOS library opening anymore (let SAS handle this)
- sendnews can now appear anywhere on the path instead of amitcp:bin
4.1 - Postnews - New command line options -R, -x (for Grn users), -a
- Postnews - Changed check for onlineness
- Postnews - Improved command line checks
3.2 - New environment variable PNS_OFFLINE
3.1 - Now uses ADOS functions
- seq file no longer needed
- ANY file in the spooldir will be sent
- the failed archive entries are separated by a line
containing the time the file failed.
- new env variable PNS_NNTPPOST allows user to specify
program to post news
2.1 - Added support for environment variables
1.x - Internal test versions
Bugs
There are currently no known bugs.
Conditions of Use
Use it how you like just remember I accept NO liability for
ANYTHING that happens.
Let me know of what you think of it, bugs, etc
Future Plans
- Improve networking code
- Improve user interface, add more options/control
- Maybe link with SpoolWatch
Give me some suggestions for other stuff
Thanks
Thanks to James Burton for the original idea and code.
Jeroen T Vermeulen for some new ideas.
Me - Nick d'Alterio
I have just completed a Physics degree at Imperial College, London and I
currently studying for a MSc Computer Science.
I have several other programs on Aminet:-
SpoolWatch - Mail/News Spool monitor comm/net
nnn - Back propagation Neural Network misc/sci
complex - Complex number functions in C dev/c
matrix - Matrix functions in C dev/c
E-Mail
nagd@oc.ic.ac.uk
------------------------------------------------------------------------------------
Nick d'Alterio (nagd@oc.ic.ac.uk)
$Id: NewPostNewsSpool.doc 1.9 1996/05/29 20:26:02 nagd Exp $